<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="../common/jspcommon.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, minimum-scale=1.0, maximum-scale=1.0">
<meta name="keywords" content="爽客网旅游，贵阳旅游，旅游" />
<meta name="description" content="爽客网旅游，贵阳旅游，旅游" />
<title>门票 - 爽客网 </title>
<link href="/css/phone/reset.css" type="text/css" rel="stylesheet" />
<link href="/css/phone/lr.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="/js/jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="/js/base.js"></script>
<script type="text/javascript" src="/js/phone/jquery.ying.js"></script>
</head>

<body>
	<div class="w320 wrap">
    	<h1 class="com_tit">
        	${product.name}
        </h1>
        <form action="wapproductbuy.htm" method="post" id="order_form">
        <input type="hidden" value="${product.id}" id="pid" name="pid"/>
       	<div class="mg_order">
            <div class="box_s2">
                <h1>线路信息</h1>
                <div class="com_box_s1">
                    <div class="top"></div>
                    <div class="content">
                        <ul class="com_ul o_hotel">
                        	<li>
                                <label>预定日期</label><select id="orderTime" name="orderTime">
                                        		<c:forEach items="${resPriceList}" var="resPrice">
                                        			<c:if test="${not empty resPrice.priceA}">
                                        				<option value="${resPrice.spDate}" price="${resPrice.priceA}">${resPrice.spDate}（${resPrice.week}）</option>
                                        			</c:if>
                                        		</c:forEach>
                                            </select>
                            </li>
                            <li>
                                <label>产品数量</label><input type="text" class="tb" id="count" name="count"/>
                            </li>
                        </ul>
                    </div>
                    <div class="bottom"></div>
                </div>
            </div>
            
            <div class="box_s2">
                <h1>联系人信息</h1>
                <div class="com_box_s1">
                    <div class="top"></div>
                    <div class="content">
                        <ul class="com_ul o_hotel">
                            <li>
                               	<label>联系人</label><input type="text" id="contactor" name="contactor"  class="tb" />
                            </li>
                            <li class="sep"></li>
                            <li>
                                <label>手机号</label><input type="text" id="phone" name="phone" class="tb" />
                            </li>
                            <li class="sep"></li>
                            <li>
                                <label>订单备注</label><input type="text" id="memo" name="memo" class="tb" />
                            </li>
                            <%--<li class="sep"></li>
                            <li>
                                <label>联系地址</label><input type="text" class="tb"  />
                            </li>
                        --%></ul>
                    </div>
                    <div class="bottom"></div>
                </div>
            </div>
            
            
            <a href="javascript:;" id="order_bt" class="def_link mb25 mt25">
            	<i class="left"></i>
                <span>下&nbsp;单</span>
                <i class="right"></i>
            </a>
            
        </div>
    	</form>
    </div>
    
    <script type="text/javascript">
    	$(function(){
    		$("#order_bt").click(function(){
    			var count = $("#count").val();
    			if(IsNull(count)){
    				alert("请输入产品数量");
    				COOL.hideLoad();
    				return ;
    			}
    			if(!GGTOOL.isNumber(count)){
    				alert("产品数量只能输入数字");
    				COOL.hideLoad();
    				return ;
    			}else if(parseInt(count) < 1){
    				alert("产品数量不能少于1");
    				COOL.hideLoad();
    				return ;
    			}
    			
    			
    			var contactor = $("#contactor").val();
	    		if(IsNull(contactor) || contactor=='联系人姓名'){
	    			alert("请输入联系人姓名");
	    			COOL.hideLoad();
	    			return ;
	    		}
	    		var phone = $("#phone").val();
	    		if(GGTOOL.mobileCheck(document.getElementById("phone"))){
	    			$("#order_form").submit();
	    		}else{
	    			COOL.hideLoad();
	    		}
    		});
    		
    	});
    </script>
</body>
</html>
